﻿using Lamex.Base;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Lamex.mCost.Common
{
    public class GetDataTable
    {
        public static DataTable GetTransfer_Package_List()
        {
            DataTable dataTable = new DataTable();
            //string sql = @"select top 10 l.Package_Mo as AUFNR,l.Material_No as MATNR,CONVERT(varchar(10),l.Product_TS,120 ) as BUDAT from Transfer_Package_List l
            //left join Transfer_Package_MO_TP tp on l.Package_Mo=tp.AUFNR
            //where tp.AUFNR is null";

//            string sql = @"  select top 1 '644025000209' as AUFNR,'4310700020' as MATNR,CONVERT(varchar(10),l.Product_TS,120 ) as BUDAT from Transfer_Package_List l
//                        left join Transfer_Package_MO_TP tp on l.Package_Mo=tp.AUFNR
//                        where tp.AUFNR is null ";

            string sql = @"  select top 1 '645073048809' as AUFNR,'9022702730' as MATNR,CONVERT(varchar(10),l.Product_TS,120 ) as BUDAT from Transfer_Package_List l
                                    left join Transfer_Package_MO_TP tp on l.Package_Mo=tp.AUFNR
                                    where tp.AUFNR is null ";

            dataTable = BaseBuildSql.GetDataTableBySql(sql);
            return dataTable;
        }
    }
}
